0

mydataset.ipynb

No Headings

The table of contents shows headings in notebooks and supported files.

Skip to Main
Jupyter

mydataset

Last Checkpoint: 1 minute ago
  • File
  • Edit
  • View
  • Run
  • Kernel
  • Settings
  • Help
JupyterLab
Python [conda env:base]
Kernel status: Idle
image/svg+xml
    [18]:
    pwd
    [18]:
    'C:\\Users\\l'
    import pandas as pd
    [38]:
    df = pd.read_csv('mydataset.csv')
    [40]:
    print(df.head())
       Rank                      Name Platform    Year         Genre Publisher  \
    0     1                Wii Sports      Wii  2006.0        Sports  Nintendo   
    1     2         Super Mario Bros.      NES  1985.0      Platform  Nintendo   
    2     3            Mario Kart Wii      Wii  2008.0        Racing  Nintendo   
    3     4         Wii Sports Resort      Wii  2009.0        Sports  Nintendo   
    4     5  Pokemon Red/Pokemon Blue       GB  1996.0  Role-Playing  Nintendo   
    
       NA_Sales  EU_Sales  JP_Sales  Other_Sales  Global_Sales  
    0     41.49     29.02      3.77         8.46         82.74  
    1     29.08      3.58      6.81         0.77         40.24  
    2     15.85     12.88      3.79         3.31         35.82  
    3     15.75     11.01      3.28         2.96         33.00  
    4     11.27      8.89     10.22         1.00         31.37  
    
    [42]:
    shape = df.shape
    [44]:
    print(f"The shape of the DataFrame is: {shape}")
    The shape of the DataFrame is: (16598, 11)
    
    [46]:
    headers = df.columns
    [48]:
    print("Headers of the dataset:")
    print(headers.tolist())
    Headers of the dataset:
    ['Rank', 'Name', 'Platform', 'Year', 'Genre', 'Publisher', 'NA_Sales', 'EU_Sales', 'JP_Sales', 'Other_Sales', 'Global_Sales']
    
    [50]:
    print(headers.tolist())
    ['Rank', 'Name', 'Platform', 'Year', 'Genre', 'Publisher', 'NA_Sales', 'EU_Sales', 'JP_Sales', 'Other_Sales', 'Global_Sales']
    
    First 5 rows of the dataset:
       Rank                      Name Platform    Year         Genre Publisher  \
    0     1                Wii Sports      Wii  2006.0        Sports  Nintendo   
    1     2         Super Mario Bros.      NES  1985.0      Platform  Nintendo   
    2     3            Mario Kart Wii      Wii  2008.0        Racing  Nintendo   
    3     4         Wii Sports Resort      Wii  2009.0        Sports  Nintendo   
    4     5  Pokemon Red/Pokemon Blue       GB  1996.0  Role-Playing  Nintendo   
    
       NA_Sales  EU_Sales  JP_Sales  Other_Sales  Global_Sales  
    0     41.49     29.02      3.77         8.46         82.74  
    1     29.08      3.58      6.81         0.77         40.24  
    2     15.85     12.88      3.79         3.31         35.82  
    3     15.75     11.01      3.28         2.96         33.00  
    4     11.27      8.89     10.22         1.00         31.37  
    Last 5 rows of the dataset:
            Rank                                              Name Platform  \
    16593  16596                Woody Woodpecker in Crazy Castle 5      GBA   
    16594  16597                     Men in Black II: Alien Escape       GC   
    16595  16598  SCORE International Baja 1000: The Official Game      PS2   
    16596  16599                                        Know How 2       DS   
    16597  16600                                  Spirits & Spells      GBA   
    
             Year     Genre   Publisher  NA_Sales  EU_Sales  JP_Sales  \
    16593  2002.0  Platform       Kemco      0.01      0.00       0.0   
    16594  2003.0   Shooter  Infogrames      0.01      0.00       0.0   
    16595  2008.0    Racing  Activision      0.00      0.00       0.0   
    16596  2010.0    Puzzle    7G//AMES      0.00      0.01       0.0   
    16597  2003.0  Platform     Wanadoo      0.01      0.00       0.0   
    
           Other_Sales  Global_Sales  
    16593          0.0          0.01  
    16594          0.0          0.01  
    16595          0.0          0.01  
    16596          0.0          0.01  
    16597          0.0          0.01  
    
    Statistical summary of the dataset:
                   Rank          Year      NA_Sales      EU_Sales      JP_Sales  \
    count  16598.000000  16327.000000  16598.000000  16598.000000  16598.000000   
    mean    8300.605254   2006.406443      0.264667      0.146652      0.077782   
    std     4791.853933      5.828981      0.816683      0.505351      0.309291   
    min        1.000000   1980.000000      0.000000      0.000000      0.000000   
    25%     4151.250000   2003.000000      0.000000      0.000000      0.000000   
    50%     8300.500000   2007.000000      0.080000      0.020000      0.000000   
    75%    12449.750000   2010.000000      0.240000      0.110000      0.040000   
    max    16600.000000   2020.000000     41.490000     29.020000     10.220000   
    
            Other_Sales  Global_Sales  
    count  16598.000000  16598.000000  
    mean       0.048063      0.537441  
    std        0.188588      1.555028  
    min        0.000000      0.010000  
    25%        0.000000      0.060000  
    50%        0.010000      0.170000  
    75%        0.040000      0.470000  
    max       10.570000     82.740000  
    
    Data types of each attribute in the dataset:
    Rank              int64
    Name             object
    Platform         object
    Year            float64
    Genre            object
    Publisher        object
    NA_Sales        float64
    EU_Sales        float64
    JP_Sales        float64
    Other_Sales     float64
    Global_Sales    float64
    dtype: object
    
    [ ]:

    Common Tools
    No metadata.
    Advanced Tools
    No metadata.
    Anaconda Assistant
    AI-powered coding, insights and debugging in your notebooks.
    To enable the following extensions, create an account or sign in.
    • Anaconda Assistant
      4.1.0
    • Coming soon!
    • Data Catalogs
    • Panel Deployments
    • Sharing
    Already have an account? Sign In
    For more information, read our Anaconda Assistant documentation.
    Alt+[
    Alt+]
    Alt+End
    • Assistant
    • Open Anaconda Assistant
      Ctrl+Shift+A
    • Console
    • Change Kernel…
    • Clear Console Cells
    • Close and Shut Down…
    • Insert Line Break
    • Interrupt Kernel
    • New Console
    • Restart Kernel…
    • Run Cell (forced)
    • Run Cell (unforced)
    • Show All Kernel Activity
    • Display Languages
    • English
      English
    • File Operations
    • Autosave Documents
    • Download
      Download the file to your computer
    • Reload Notebook from Disk
      Reload contents from disk
    • Revert Notebook to Checkpoint…
      Revert contents to previous checkpoint
    • Save Notebook
      Save and create checkpoint
      Ctrl+S
    • Save Notebook As…
      Save with new path
      Ctrl+Shift+S
    • Trust HTML File
      Whether the HTML file is trusted. Trusting the file allows scripts to run in it, which may result in security risks. Only enable for files you trust.
    • Help
    • About Jupyter Notebook
    • Jupyter Reference
    • JupyterLab FAQ
    • JupyterLab Reference
    • Launch Jupyter Notebook File Browser
    • Markdown Reference
    • Show Keyboard Shortcuts…
      Show relevant keyboard shortcuts for the current active widget
      Ctrl+Shift+H
    • Image Viewer
    • Flip image horizontally
      H
    • Flip image vertically
      V
    • Invert Colors
      I
    • Reset Image
      0
    • Rotate Clockwise
      ]
    • Rotate Counterclockwise
      [
    • Zoom In
      =
    • Zoom Out
      -
    • Kernel Operations
    • Shut Down All Kernels…
    • Main Area
    • Close All Other Tabs
    • Close Tab
      Alt+W
    • Close Tabs to Right
    • End Search
      Esc
    • Find Next
      Ctrl+G
    • Find Previous
      Ctrl+Shift+G
    • Find…
      Ctrl+F
    • Log Out
      Log out of Jupyter Notebook
    • Search in Selection
      Alt+L
    • Shut Down
      Shut down Jupyter Notebook
    • Mode
    • Toggle Zen Mode
    • Notebook Cell Operations
    • Change to Code Cell Type
      Y
    • Change to Heading 1
      1
    • Change to Heading 2
      2
    • Change to Heading 3
      3
    • Change to Heading 4
      4
    • Change to Heading 5
      5
    • Change to Heading 6
      6
    • Change to Markdown Cell Type
      M
    • Change to Raw Cell Type
      R
    • Clear Cell Output
      Clear outputs for the selected cells
    • Collapse All Code
    • Collapse All Outputs
    • Collapse Selected Code
    • Collapse Selected Outputs
    • Copy Cell
      Copy this cell
      C
    • Cut Cell
      Cut this cell
      X
    • Delete Cell
      Delete this cell
      D, D
    • Disable Scrolling for Outputs
    • Enable Scrolling for Outputs
    • Expand All Code
    • Expand All Outputs
    • Expand Selected Code
    • Expand Selected Outputs
    • Extend Selection Above
      Shift+K
    • Extend Selection Below
      Shift+J
    • Extend Selection to Bottom
      Shift+End
    • Extend Selection to Top
      Shift+Home
    • Insert Cell Above
      Insert a cell above
      A
    • Insert Cell Below
      Insert a cell below
      B
    • Insert Heading Above Current Heading
      Shift+A
    • Insert Heading Below Current Heading
      Shift+B
    • Merge Cell Above
      Ctrl+Backspace
    • Merge Cell Below
      Ctrl+Shift+M
    • Merge Selected Cells
      Shift+M
    • Move Cell Down
      Move this cell down
      Ctrl+Shift+Down
    • Move Cell Up
      Move this cell up
      Ctrl+Shift+Up
    • Paste Cell Above
      Paste this cell from the clipboard
    • Paste Cell and Replace
    • Paste Cell Below
      Paste this cell from the clipboard
      V
    • Redo Cell Operation
      Shift+Z
    • Render Side-by-Side
      Shift+R
    • Run Selected Cell
      Run this cell and advance
      Shift+Enter
    • Run Selected Cell and Do not Advance
      Ctrl+Enter
    • Run Selected Cell and Insert Below
      Alt+Enter
    • Run Selected Text or Current Line in Console
    • Select Cell Above
      K
    • Select Cell Below
      J
    • Select Heading Above or Collapse Heading
      Left
    • Select Heading Below or Expand Heading
      Right
    • Set side-by-side ratio
    • Split Cell
      Ctrl+Shift+-
    • Undo Cell Operation
      Z
    • Notebook Operations
    • Access Next Kernel History Entry
      Alt+Down
    • Access Previous Kernel History Entry
      Alt+Up
    • Change Kernel…
    • Clear Outputs of All Cells
      Clear all outputs of all cells
    • Close and Shut Down Notebook…
    • Collapse All Headings
      Ctrl+Shift+Left
    • Deselect All Cells
    • Edit Notebook Metadata
    • Enter Command Mode
      Ctrl+M
    • Enter Edit Mode
      Enter
    • Expand All Headings
      Ctrl+Shift+Right
    • Interrupt Kernel
      Interrupt the kernel
    • New Console for Notebook
    • New Notebook
      Create a new notebook
    • Open with Panel in New Browser Tab
    • Preview Notebook with Panel
    • Reconnect to Kernel
    • Render All Markdown Cells
    • Restart Kernel and Clear Outputs of All Cells…
      Restart the kernel and clear all outputs of all cells
    • Restart Kernel and Debug…
      Restart Kernel and Debug…
    • Restart Kernel and Run All Cells…
      Restart the kernel and run all cells
    • Restart Kernel and Run up to Selected Cell…
    • Restart Kernel…
      Restart the kernel
    • Run All Above Selected Cell
    • Run All Cells
      Run all cells
    • Run Selected Cell and All Below
    • Save and Export Notebook: Asciidoc
    • Save and Export Notebook: Executable Script
    • Save and Export Notebook: HTML
    • Save and Export Notebook: LaTeX
    • Save and Export Notebook: Markdown
    • Save and Export Notebook: PDF
    • Save and Export Notebook: Qtpdf
    • Save and Export Notebook: Qtpng
    • Save and Export Notebook: ReStructured Text
    • Save and Export Notebook: Reveal.js Slides
    • Save and Export Notebook: Webpdf
    • Select All Cells
      Ctrl+A
    • Show Line Numbers
    • Toggle Collapse Notebook Heading
    • Trust Notebook
    • Other
    • Open in JupyterLab
      JupyterLab
    • Plugin Manager
    • Advanced Plugin Manager
    • Terminal
    • Decrease Terminal Font Size
    • Increase Terminal Font Size
    • New Terminal
      Start a new terminal session
    • Refresh Terminal
      Refresh the current terminal session
    • Use Terminal Theme: Dark
      Set the terminal theme
    • Use Terminal Theme: Inherit
      Set the terminal theme
    • Use Terminal Theme: Light
      Set the terminal theme
    • Text Editor
    • Decrease Font Size
    • Increase Font Size
    • New Markdown File
      Create a new markdown file
    • New Python File
      Create a new Python file
    • New Text File
      Create a new text file
    • Spaces: 1
    • Spaces: 2
    • Spaces: 4
    • Spaces: 4
    • Spaces: 8
    • Theme
    • Decrease Code Font Size
    • Decrease Content Font Size
    • Decrease UI Font Size
    • Increase Code Font Size
    • Increase Content Font Size
    • Increase UI Font Size
    • Set Preferred Dark Theme: JupyterLab Dark
    • Set Preferred Dark Theme: JupyterLab Dark High Contrast
    • Set Preferred Dark Theme: JupyterLab Light
    • Set Preferred Light Theme: JupyterLab Dark
    • Set Preferred Light Theme: JupyterLab Dark High Contrast
    • Set Preferred Light Theme: JupyterLab Light
    • Synchronize Styling Theme with System Settings
    • Theme Scrollbars
    • Use Theme: JupyterLab Dark
    • Use Theme: JupyterLab Dark High Contrast
    • Use Theme: JupyterLab Light
    • View
    • File Browser
    • Open JupyterLab
    • Show Anaconda Assistant
      Show Show Anaconda Assistant in the right sidebar
    • Show Header
    • Show Notebook Tools
      Show Show Notebook Tools in the right sidebar
    • Show Table of Contents
      Show Show Table of Contents in the left sidebar